Skip to content

qcom-7.2 backport: Use gdsc_synced_poweroff_disable() callback for USB PHY GDSCs on Glymur - #1184

Open
kona-jagadeesh wants to merge 2 commits into
qualcomm-linux:qcom-7.2from
kona-jagadeesh:glymur-usb-phy-gdsc
Open

kona-jagadeesh wants to merge 2 commits into
qualcomm-linux:qcom-7.2from
kona-jagadeesh:glymur-usb-phy-gdsc

Conversation

@kona-jagadeesh

@kona-jagadeesh kona-jagadeesh commented Sep 24, 2026 •

Copy link
Copy Markdown

This series includes changes to use gdsc_synced_poweroff_disable() callback for gcc_usb_0_phy_gdsc and gcc_usb_1_phy_gdsc on Glymur platform. With this change, these GDSCs get disabled only when USB drivers explicitly invoke dev_pm_genpd_synced_poweroff() before suspend, else GDSCs stay ON during suspend.

This is backport to Glymur qcom-7.2 release branch and mainline line PR: qualcomm-linux/kernel-topics#1917 is under review with QLI exception JIRA: https://jira-dc.qualcomm.com/jira/browse/QLIJIRA-215

BACKPORT: qualcomm-linux/kernel-topics#1917
CRs-fixed: 4689959

@qcomlnxci

Copy link
Copy Markdown

Test Matrix

Test Case glymur-crd-multimedia
Audio_Card_Registration ✅ Pass
BT_FW_KMD_Service ✅ Pass
BT_ON_OFF ✅ Pass
BT_SCAN ✅ Pass
CPUFreq_Validation ✅ Pass
CPU_affinity ✅ Pass
DSP_AudioPD ✅ Pass
Ethernet_Basic_Validation ⚠️ skip
Freq_Scaling ✅ Pass
GIC ✅ Pass
IPA ✅ Pass
Interrupts ✅ Pass
KVM_Driver ✅ Pass
KVM_EL2_DTB ✅ Pass
KVM_Infra ✅ Pass
OpenCV ✅ Pass
PCIe ✅ Pass
Probe_Failure_Check ❌ Fail
RMNET ✅ Pass
UFS_Validation ⚠️ skip
USBHost ✅ Pass
WiFi_Firmware_Driver ✅ Pass
WiFi_OnOff ✅ Pass
adsp_remoteproc ✅ Pass
cdsp_remoteproc ✅ Pass
gpdsp_remoteproc ⚠️ skip
hotplug ✅ Pass
irq ✅ Pass
kaslr ✅ Pass
pinctrl ✅ Pass
qcom_hwrng ✅ Pass
rngtest ✅ Pass
shmbridge ✅ Pass
smmu ❌ Fail
watchdog ✅ Pass
wpss_remoteproc ✅ Pass

@qcomlnxci

Copy link
Copy Markdown

Test jobs on 640c294

@kona-jagadeesh
kona-jagadeesh force-pushed the glymur-usb-phy-gdsc branch 3 times, most recently from d2ed939 to 8259207 Compare September 25, 2026 06:47
@qcomlnxci

Copy link
Copy Markdown

Test Matrix

Test Case glymur-crd-multimedia
Audio_Card_Registration ✅ Pass
BT_FW_KMD_Service ✅ Pass
BT_ON_OFF ✅ Pass
BT_SCAN ✅ Pass
CPUFreq_Validation ✅ Pass
CPU_affinity ✅ Pass
DSP_AudioPD ✅ Pass
Ethernet_Basic_Validation ⚠️ skip
Freq_Scaling ✅ Pass
GIC ✅ Pass
IPA ✅ Pass
Interrupts ✅ Pass
KVM_Driver ✅ Pass
KVM_EL2_DTB ✅ Pass
KVM_Infra ✅ Pass
OpenCV ✅ Pass
PCIe ✅ Pass
Probe_Failure_Check ❌ Fail
RMNET ✅ Pass
UFS_Validation ⚠️ skip
USBHost ✅ Pass
WiFi_Firmware_Driver ✅ Pass
WiFi_OnOff ✅ Pass
adsp_remoteproc ✅ Pass
cdsp_remoteproc ✅ Pass
gpdsp_remoteproc ⚠️ skip
hotplug ✅ Pass
irq ✅ Pass
kaslr ✅ Pass
pinctrl ✅ Pass
qcom_hwrng ✅ Pass
rngtest ✅ Pass
shmbridge ✅ Pass
smmu ❌ Fail
watchdog ✅ Pass
wpss_remoteproc ✅ Pass

@qcomlnxci

Copy link
Copy Markdown

Test jobs on d2ed939

@qcomlnxci

Copy link
Copy Markdown

Test Matrix

Test Case glymur-crd-multimedia
Audio_Card_Registration ✅ Pass
BT_FW_KMD_Service ✅ Pass
BT_ON_OFF ✅ Pass
BT_SCAN ✅ Pass
CPUFreq_Validation ✅ Pass
CPU_affinity ✅ Pass
DSP_AudioPD ✅ Pass
Ethernet_Basic_Validation ⚠️ skip
Freq_Scaling ✅ Pass
GIC ✅ Pass
IPA ✅ Pass
Interrupts ✅ Pass
KVM_Driver ✅ Pass
KVM_EL2_DTB ✅ Pass
KVM_Infra ✅ Pass
OpenCV ✅ Pass
PCIe ✅ Pass
Probe_Failure_Check ❌ Fail
RMNET ✅ Pass
UFS_Validation ⚠️ skip
USBHost ✅ Pass
WiFi_Firmware_Driver ✅ Pass
WiFi_OnOff ✅ Pass
adsp_remoteproc ✅ Pass
cdsp_remoteproc ✅ Pass
gpdsp_remoteproc ⚠️ skip
hotplug ✅ Pass
irq ✅ Pass
kaslr ✅ Pass
pinctrl ✅ Pass
qcom_hwrng ✅ Pass
rngtest ✅ Pass
shmbridge ✅ Pass
smmu ❌ Fail
watchdog ✅ Pass
wpss_remoteproc ✅ Pass

@qcomlnxci

Copy link
Copy Markdown

Test jobs on 03de3c1

@qcomlnxci

Copy link
Copy Markdown

Test Matrix

Test Case glymur-crd-multimedia
Audio_Card_Registration ✅ Pass
BT_FW_KMD_Service ✅ Pass
BT_ON_OFF ✅ Pass
BT_SCAN ✅ Pass
CPUFreq_Validation ✅ Pass
CPU_affinity ✅ Pass
DSP_AudioPD ✅ Pass
Ethernet_Basic_Validation ⚠️ skip
Freq_Scaling ✅ Pass
GIC ✅ Pass
IPA ✅ Pass
Interrupts ✅ Pass
KVM_Driver ✅ Pass
KVM_EL2_DTB ✅ Pass
KVM_Infra ✅ Pass
OpenCV ✅ Pass
PCIe ✅ Pass
Probe_Failure_Check ❌ Fail
RMNET ✅ Pass
UFS_Validation ⚠️ skip
USBHost ✅ Pass
WiFi_Firmware_Driver ✅ Pass
WiFi_OnOff ✅ Pass
adsp_remoteproc ✅ Pass
cdsp_remoteproc ✅ Pass
gpdsp_remoteproc ⚠️ skip
hotplug ✅ Pass
irq ✅ Pass
kaslr ✅ Pass
pinctrl ✅ Pass
qcom_hwrng ✅ Pass
rngtest ✅ Pass
shmbridge ✅ Pass
smmu ❌ Fail
watchdog ✅ Pass
wpss_remoteproc ✅ Pass

@qcomlnxci

Copy link
Copy Markdown

Test jobs on 8259207

USB and PCIe GDSCs must remain enabled during system suspend for USB host
mode and PCIe non-D3cold use cases.

These GDSCs currently use PWRSTS_RET_ON in the GDSC driver, which prevents
the gdsc driver from disabling them in hardware after the first enable.
Consequently, they remain enabled indefinitely, even after their consumers
become inactive, preventing the GDSCs from being powered off when no longer
needed.

Instead, use the GenPDs synced_poweroff flag to control whether a GDSC is
disabled during suspend. USB and PCIe drivers can leave the flag unset when
the GDSC must remain enabled, and set it when the GDSC should be powered
off. This allows consumer drivers to have more dynamic control over the
GDSC power state based on their current use case.

The existing gdsc_gx_gdsc() callback also disables the GDSC based on
synced_poweroff flag but it polls for GDSC status during disable if synced
poweroff flag is set. But few PCIE GDSCs have a VOTABLE flag and should not
be polled for status during disable. Hence introduce a new
gdsc_synced_poweroff_disable() callback that disables the GDSC based on
GenPD synced_poweroff flag but won't poll for status if GDSC has VOTABLE
flag.

Signed-off-by: Jagadeesh Kona <jagadeesh.kona@oss.qualcomm.com>
Use the gdsc_synced_poweroff_disable() as power_off callback for USB
GDSCs on Glymur platform.

This allows the GDSCs to be disabled during suspend only when the consumer
driver explicitly calls dev_pm_genpd_synced_poweroff() before suspend.
Consumer drivers can therefore keep the GDSCs powered on during system
suspend by not calling dev_pm_genpd_synced_poweroff() before suspend.

Signed-off-by: Jagadeesh Kona <jagadeesh.kona@oss.qualcomm.com>
@qcomlnxci

Copy link
Copy Markdown

Test Matrix

Test Case glymur-crd-multimedia
Audio_Card_Registration ✅ Pass
BT_FW_KMD_Service ✅ Pass
BT_ON_OFF ✅ Pass
BT_SCAN ✅ Pass
CPUFreq_Validation ✅ Pass
CPU_affinity ✅ Pass
DSP_AudioPD ✅ Pass
Ethernet_Basic_Validation ⚠️ skip
Freq_Scaling ✅ Pass
GIC ✅ Pass
IPA ✅ Pass
Interrupts ✅ Pass
KVM_Driver ✅ Pass
KVM_EL2_DTB ✅ Pass
KVM_Infra ✅ Pass
OpenCV ✅ Pass
PCIe ✅ Pass
Probe_Failure_Check ❌ Fail
RMNET ✅ Pass
UFS_Validation ⚠️ skip
USBHost ✅ Pass
WiFi_Firmware_Driver ✅ Pass
WiFi_OnOff ✅ Pass
adsp_remoteproc ✅ Pass
cdsp_remoteproc ✅ Pass
gpdsp_remoteproc ⚠️ skip
hotplug ✅ Pass
irq ✅ Pass
kaslr ✅ Pass
pinctrl ✅ Pass
qcom_hwrng ✅ Pass
rngtest ✅ Pass
shmbridge ✅ Pass
smmu ❌ Fail
watchdog ✅ Pass
wpss_remoteproc ✅ Pass

@qcomlnxci

Copy link
Copy Markdown

Test jobs on d2679cd

@qswat-orbit-external

Copy link
Copy Markdown

Merge Check Failed: No CR Numbers Found

Error: No Change Request numbers were found.

Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests.

@kona-jagadeesh kona-jagadeesh changed the title Use gdsc_synced_poweroff_disable() callback for USB PHY GDSCs on Glymur qcom-7.2 backport: Use gdsc_synced_poweroff_disable() callback for USB PHY GDSCs on Glymur Sep 28, 2026
@qswat-orbit-external

Copy link
Copy Markdown

Merge Check Failed: No Component Found

Configuration Error: No component found for branch 'qcom-7.2'.

There is no component associated with the provided branch in Polaris. Please verify the branch configuration.

Branch: qcom-7.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants